// 库存管理接口
import request from "@/common/request.js";
const api = {
  role: "/role/",
};

const acRoleApi = {
  get_role(params) {
    return request({
      url: api.role,
      method: "get",
      params,
    });
  },

  role_detail(id) {
    return request({
      url: api.role + id,
      method: "get",
    });
  },

  post_role(data) {
    return request({
      url: api.role,
      method: "post",
      data,
    });
  },

  patch_role(data, id) {
    return request({
      url: api.role + id + "/",
      method: "patch",
      data,
    });
  },

  delete_role(id) {
    return request({
      url: api.role + id + "/",
      method: "delete",
    });
  },
};
export default acRoleApi;
